<template>
  <div class="header-box">
    <slot name="left">
      <div class="header-left">
        <slot name="left-icon">
          <i :class="`font_family ${icon}`"></i>
        </slot>
        <slot name="left-title">
          <span>{{ title }}</span>
        </slot>
      </div>
    </slot>
    <div class="header-right">
      <slot name="right"></slot>
    </div>
  </div>
</template>
<script lang="ts" setup>
defineProps({
  title: {
    type: String,
    default: '',
  },
  icon: {
    type: String,
    default: 'icon-chanpinguanli',
  },
})
</script>
<style lang="less" scoped>
.header-box {
  padding: 12px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  .header-left {
    display: flex;
    align-items: center;
    font-size: 28px;
    span {
      margin-left: 10px;
      font-family: MicrosoftYaHeiSemibold;
      font-size: 16px;
      color: #303133;
      line-height: 28px;
      text-align: left;
      font-style: normal;
      text-transform: none;
    }
  }
}
</style>
